<?php


namespace XiaoGuai\DataStructure\Huffman\HuffmanTree;


class HuffmanTreeNode
{

    /**
     * @var int INVALID_INDEX 无效索引
     */
    const INVALID_INDEX = -1;

    /**
     * @var null|int 叶子结点权重
     */
    public $weight = null;

    /**
     * @var null|int 父结点的索引
     */
    public $parent = null;

    /**
     * @var null|int 左孩子的索引
     */
    public $leftChild = null;

    /**
     * @var null|int 右孩子的索引
     */
    public $rightChild = null;

}